<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Title</title>
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
</head>
<body>
<div id="app">
    <h1>{{msg}}</h1>
    <h1>{{number}}</h1>
</div>

<script>
    let options = {
        data: {
            number: 100
        },
        created: () => {
            console.log("vue的生命周期created")
        },
        beforeMount: () => {
            console.log("vue的生命周期beforeMount")
        },
        Mounted: () => {
            console.log("vue的生命周期Mounted")
        }
    }
    let app = new Vue({
        el: '#app',
        data: {
            msg: "hello, world"
        },
        mixins:[options]
    })
</script>
</body>
</html>